import request from '@/utils/request'
// DELETE /edu/video/delVideo/{id}
// 课程小节删除 按小节id删除

export function deleteVideo(id) {
  return request({
    url: `/edu/video/delVideo/${id}`,
    method: 'delete'
  })
}

// PUT /edu/video/editVideo
// 课程小节修改 按小节实体修改
export function editVideo(video) {
  return request({
    url: `/edu/video/editVideo`,
    method: 'put',
    data: video
  })
}

// GET /edu/video/getVideo/{id}
// 课程小节查询 按小节id查询
export function getVideo(id) {
  return request({
    url: `/edu/video/getVideo/${id}`,
    method: 'get'
  })
}

// POST /edu/video/saveVideo
// 课程小节添加 按小节实体添加
export function saveVideo(video) {
  return request({
    url: `/edu/video/saveVideo`,
    method: 'post',
    data: video
  })
}
// 删除阿里云视频
export function deleteAlyVideo(videoSourceId) {
  return request({
    url: `/eduvod/service/delVideo/${videoSourceId}`,
    method: 'delete'
  })
}
